﻿<Window
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
        xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
        xmlns:local="clr-namespace:MALRECrewrite.Etc"
        xmlns:ed="http://schemas.microsoft.com/expression/2010/drawing"
        xmlns:my="http://schemas.awesomium.com/winfx" xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity" xmlns:ei="http://schemas.microsoft.com/expression/2010/interactions"
        xmlns:System="clr-namespace:System;assembly=mscorlib"
        xmlns:Microsoft_Windows_Themes="clr-namespace:Microsoft.Windows.Themes;assembly=PresentationFramework.Aero"
        xmlns:ee="http://schemas.microsoft.com/expression/2010/effects"
        xmlns:models="clr-namespace:MALRECrewrite.Models"
        mc:Ignorable="d"
        x:Class="MALRECrewrite.MainWindow"
        Title="MALRec"
        Height="634" Width="882" Icon="/MALRECrewrite;component/Unbenannt-1.ico" d:DataContext="{d:DesignData /SampleData/ViewModelSampleData.xaml}">
    <Window.Resources>
    	<BooleanToVisibilityConverter x:Key="BooleanToVisibilityConverter"/>
        <local:ImageCacheConverter x:Key="ImageCacheConverter"/>
        <local:StringListToCommasConverter x:Key="StringListToCommasConverter"/>
        <DataTemplate x:Key="AnimeTemplate">
            <StackPanel>
                <CheckBox Content="{Binding Title}" Style="{DynamicResource AnimeCheckbox}"/>
                <TextBlock Text="{Binding Score}"/>
                <TextBlock Text="{Binding Status}"/>
            </StackPanel>
        </DataTemplate>
        <SolidColorBrush x:Key="HighlightBrush" Color="#E62E51A2"/>
        <DataTemplate x:Key="SortedRecommendationTemplate">
            <Border x:Name="border1" BorderBrush="{x:Null}" BorderThickness="0" Margin="5" Width="120" Height="150" Background="#00000000" HorizontalAlignment="Stretch">
                <i:Interaction.Behaviors>
                    <ei:DataStateBehavior Binding="{Binding ShowAllInfo}" Value="True" TrueState="AllInfoState" FalseState="OnlyNameState"/>
                </i:Interaction.Behaviors>
                <i:Interaction.Triggers>
                    <i:EventTrigger EventName="MouseEnter">
                		<i:Interaction.Behaviors>
                			<ei:ConditionBehavior>
                				<ei:ConditionalExpression>
                					<ei:ComparisonCondition LeftOperand="{Binding ShowAllInfo}" RightOperand="False"/>
                				</ei:ConditionalExpression>
                			</ei:ConditionBehavior>
                		</i:Interaction.Behaviors>
                		<ei:GoToStateAction StateName="AllInfoState"/>
                	</i:EventTrigger>
                    <i:EventTrigger EventName="MouseLeave">
                    	<i:Interaction.Behaviors>
                    		<ei:ConditionBehavior>
                    			<ei:ConditionalExpression>
                    				<ei:ComparisonCondition LeftOperand="{Binding ShowAllInfo}" RightOperand="False"/>
                    			</ei:ConditionalExpression>
                    		</ei:ConditionBehavior>
                    	</i:Interaction.Behaviors>
                    	<ei:GoToStateAction StateName="OnlyNameState"/>
                    </i:EventTrigger>
                    <i:EventTrigger>
                        <ei:GoToStateAction StateName="OnlyNameState" UseTransitions="False"/>
                    </i:EventTrigger>
                </i:Interaction.Triggers>
                <VisualStateManager.VisualStateGroups>
                    <VisualStateGroup x:Name="VisualStateGroup">
                        <VisualStateGroup.Transitions>
                            <VisualTransition GeneratedDuration="0" To="OnlyNameState">
                                <Storyboard>
                            		<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)" Storyboard.TargetName="border_Copy">
                            			<EasingDoubleKeyFrame KeyTime="0:0:0.2" Value="0">
                            				<EasingDoubleKeyFrame.EasingFunction>
                            					<CircleEase EasingMode="EaseOut"/>
                            				</EasingDoubleKeyFrame.EasingFunction>
                            			</EasingDoubleKeyFrame>
                            		</DoubleAnimationUsingKeyFrames>
                            		<DoubleAnimation Duration="0:0:0.2" To="0" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)" Storyboard.TargetName="border2"/>
                            	</Storyboard>
                            </VisualTransition>
                            <VisualTransition From="OnlyNameState" GeneratedDuration="0">
                                <Storyboard>
                            		<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)" Storyboard.TargetName="border_Copy">
                            			<EasingDoubleKeyFrame KeyTime="0:0:0.2" Value="-90">
                            				<EasingDoubleKeyFrame.EasingFunction>
                            					<CubicEase EasingMode="EaseIn"/>
                            				</EasingDoubleKeyFrame.EasingFunction>
                            			</EasingDoubleKeyFrame>
                            		</DoubleAnimationUsingKeyFrames>
                            		<DoubleAnimation Duration="0:0:0.2" To="20" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)" Storyboard.TargetName="border2"/>
                            	</Storyboard>
                            </VisualTransition>
                            <VisualTransition From="OnlyNameState" GeneratedDuration="0" To="AllInfoState">
                                <Storyboard>
                            		<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)" Storyboard.TargetName="border_Copy">
                            			<EasingDoubleKeyFrame KeyTime="0:0:0.3" Value="-90">
                            				<EasingDoubleKeyFrame.EasingFunction>
                            					<CubicEase EasingMode="EaseIn"/>
                            				</EasingDoubleKeyFrame.EasingFunction>
                            			</EasingDoubleKeyFrame>
                            		</DoubleAnimationUsingKeyFrames>
                            		<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)" Storyboard.TargetName="border">
                            			<EasingDoubleKeyFrame KeyTime="0:0:0.3" Value="0">
                            				<EasingDoubleKeyFrame.EasingFunction>
                            					<CubicEase EasingMode="EaseIn"/>
                            				</EasingDoubleKeyFrame.EasingFunction>
                            			</EasingDoubleKeyFrame>
                            		</DoubleAnimationUsingKeyFrames>
                            		<DoubleAnimation Duration="0:0:0.3" To="20" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)" Storyboard.TargetName="border2"/>
                            	</Storyboard>
                            </VisualTransition>
                            <VisualTransition From="AllInfoState" GeneratedDuration="0" To="OnlyNameState">
                                <Storyboard>
                            		<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)" Storyboard.TargetName="border">
                            			<EasingDoubleKeyFrame KeyTime="0:0:0.3" Value="151">
                            				<EasingDoubleKeyFrame.EasingFunction>
                            					<CubicEase EasingMode="EaseIn"/>
                            				</EasingDoubleKeyFrame.EasingFunction>
                            			</EasingDoubleKeyFrame>
                            		</DoubleAnimationUsingKeyFrames>
                            		<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)" Storyboard.TargetName="border_Copy">
                            			<EasingDoubleKeyFrame KeyTime="0:0:0.3" Value="0">
                            				<EasingDoubleKeyFrame.EasingFunction>
                            					<CircleEase EasingMode="EaseOut"/>
                            				</EasingDoubleKeyFrame.EasingFunction>
                            			</EasingDoubleKeyFrame>
                            		</DoubleAnimationUsingKeyFrames>
                            		<DoubleAnimation Duration="0:0:0.3" To="0" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)" Storyboard.TargetName="border2"/>
                            	</Storyboard>
                            </VisualTransition>
                            <VisualTransition GeneratedDuration="0:0:0.3" To="Expanded"/>
                            <VisualTransition From="Expanded" GeneratedDuration="0:0:0.3"/>
                        </VisualStateGroup.Transitions>
                        <VisualState x:Name="OnlyNameState">
                            <Storyboard>
                                <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)" Storyboard.TargetName="border_Copy">
                                    <EasingDoubleKeyFrame KeyTime="0" Value="0"/>
                                </DoubleAnimationUsingKeyFrames>
                                <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)" Storyboard.TargetName="border2">
                                	<EasingDoubleKeyFrame KeyTime="0" Value="0"/>
                                </DoubleAnimationUsingKeyFrames>
                            </Storyboard>
                        </VisualState>
                        <VisualState x:Name="OnlyImageState"/>
                        <VisualState x:Name="AllInfoState">
                            <Storyboard>
                                <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)" Storyboard.TargetName="border">
                                    <EasingDoubleKeyFrame KeyTime="0" Value="0"/>
                                </DoubleAnimationUsingKeyFrames>
                            </Storyboard>
                        </VisualState>
                        <VisualState x:Name="Expanded">
                        	<Storyboard>
                        		<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(FrameworkElement.Width)" Storyboard.TargetName="border1">
                        			<EasingDoubleKeyFrame KeyTime="0" Value="240"/>
                        		</DoubleAnimationUsingKeyFrames>
                        		<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)" Storyboard.TargetName="border">
                        			<EasingDoubleKeyFrame KeyTime="0" Value="0"/>
                        		</DoubleAnimationUsingKeyFrames>
                        	</Storyboard>
                        </VisualState>
                    </VisualStateGroup>
                </VisualStateManager.VisualStateGroups>
                <Grid HorizontalAlignment="Stretch">
                	<Grid.ColumnDefinitions>
                		<ColumnDefinition Width="120"/>
                		<ColumnDefinition Width="120"/>
                	</Grid.ColumnDefinitions>
            		<Grid Height="Auto" ClipToBounds="True" HorizontalAlignment="Left" VerticalAlignment="Top" Width="120">
            			<Border Height="150" Margin="0" Grid.Row="1" Width="120" BorderThickness="1" BorderBrush="{DynamicResource HighlightBrush}">
            				<Image StretchDirection="Both" Stretch="UniformToFill" >
            					<Image.Source>
            						<MultiBinding Converter="{StaticResource ImageCacheConverter}" >
            							<Binding Path="Image"/>
            							<Binding Path="Aid"/>
            						</MultiBinding>
            					</Image.Source>
            				</Image>
            			</Border>
            			<Border x:Name="border" Margin="0" Grid.Row="1" Background="{DynamicResource HighlightBrush}" Padding="3" Visibility="Visible" RenderTransformOrigin="0.5,0.5" >
            				<Border.RenderTransform>
            					<TransformGroup>
            						<ScaleTransform/>
            						<SkewTransform/>
            						<RotateTransform/>
            						<TranslateTransform Y="151"/>
            					</TransformGroup>
            				</Border.RenderTransform>
            				<Grid Margin="0">
            					<StackPanel HorizontalAlignment="Right" Orientation="Vertical" VerticalAlignment="Bottom">
            						<Button Content="➜" HorizontalAlignment="Right" Style="{DynamicResource ButtonStyle1}" VerticalAlignment="Stretch" Margin="0,0,0,2" d:LayoutOverrides="Width">
            							<i:Interaction.Triggers>
            								<i:EventTrigger EventName="Click">
            									<ei:GoToStateAction StateName="Expanded"/>
            								</i:EventTrigger>
            							</i:Interaction.Triggers>
            						</Button>
            						<StackPanel x:Name="stackPanel_Copy" Orientation="Horizontal" Height="Auto" Width="Auto" HorizontalAlignment="Stretch" Margin="0" VerticalAlignment="Stretch" d:LayoutOverrides="Width">
            							<Image Source="/MALRECrewrite;component/Etc/Flags/de.png" HorizontalAlignment="Left" VerticalAlignment="Top" Width="16" Height="11" Margin="2,0,0,0" Visibility="{Binding IsGerman, Converter={StaticResource BooleanToVisibilityConverter}}"/>
            							<Image Source="/MALRECrewrite;component/Etc/Flags/gb.png" HorizontalAlignment="Left" VerticalAlignment="Top" Width="16" Height="11" Margin="2,0,0,0" Visibility="{Binding IsEnglish, Converter={StaticResource BooleanToVisibilityConverter}}"/>
            							<Image Source="/MALRECrewrite;component/Etc/Flags/jp.png" HorizontalAlignment="Left" VerticalAlignment="Top" Width="16" Height="11" Margin="2,0,0,0" Visibility="{Binding IsJapanese, Converter={StaticResource BooleanToVisibilityConverter}}"/>
            							<Image Source="/MALRECrewrite;component/Etc/Flags/u.png" HorizontalAlignment="Left" VerticalAlignment="Top" Width="16" Height="11" Visibility="{Binding LangUnknown, Converter={StaticResource BooleanToVisibilityConverter}}" Margin="2,0,0,0"/>
            						</StackPanel>
            					</StackPanel>
            					<StackPanel VerticalAlignment="Top" Margin="0" >
            						<Border Margin="0" VerticalAlignment="Top" BorderBrush="White" BorderThickness="0,0,0,1">
            							<TextBlock TextWrapping="Wrap" Text="{Binding Title}" Foreground="White" FontFamily="Segoe UI" FontWeight="Normal" Height="15.96"/>
            						</Border>
            						<TextBlock TextWrapping="Wrap" Text="{Binding CountSum, StringFormat=Count: {0}}" VerticalAlignment="Stretch" Foreground="White" FontFamily="Segoe UI" Margin="0,4,0,0"/>
            						<TextBlock TextWrapping="Wrap" Text="{Binding SourceSum, StringFormat=Sources: {0}}" VerticalAlignment="Stretch" Foreground="White" FontFamily="Segoe UI" Margin="0,0,0,5"/>
            						<Border Margin="0" BorderBrush="White" BorderThickness="0,1,0,0">
            							<TextBlock TextWrapping="Wrap" Text="{Binding Genres, Converter={StaticResource StringListToCommasConverter}, StringFormat=Genres: \{0\}}" Foreground="White" FontSize="9.333" Height="111.72"/>
            						</Border>
            					</StackPanel>
            				</Grid>
            			</Border>
            			<Border x:Name="border_Copy" Margin="0" Grid.Row="1" Background="{DynamicResource HighlightBrush}" Padding="3" Visibility="Visible" RenderTransformOrigin="0.5,0.5" VerticalAlignment="Top" >
            				<Border.RenderTransform>
            					<TransformGroup>
            						<ScaleTransform/>
            						<SkewTransform/>
            						<RotateTransform/>
            						<TranslateTransform Y="-90"/>
            					</TransformGroup>
            				</Border.RenderTransform>
            				<StackPanel VerticalAlignment="Top" >
            					<TextBlock TextWrapping="Wrap" Text="{Binding Title}" VerticalAlignment="Top" Foreground="White" FontFamily="Segoe UI" HorizontalAlignment="Left"/>
            				</StackPanel>
            			</Border>
            		</Grid>
            		<Border x:Name="border2" HorizontalAlignment="Right" Margin="0" VerticalAlignment="Bottom" Padding="3" Background="{DynamicResource HighlightBrush}" RenderTransformOrigin="0.5,0.5" >
            			<Border.RenderTransform>
            				<TransformGroup>
            					<ScaleTransform/>
            					<SkewTransform/>
            					<RotateTransform/>
            					<TranslateTransform Y="20"/>
            				</TransformGroup>
            			</Border.RenderTransform>
            			<StackPanel x:Name="stackPanel" Orientation="Horizontal" Height="Auto" Width="Auto">
            				<Image Source="/MALRECrewrite;component/Etc/Flags/de.png" HorizontalAlignment="Left" VerticalAlignment="Top" Width="16" Height="11" Margin="0,0,2,0" Visibility="{Binding IsGerman, Converter={StaticResource BooleanToVisibilityConverter}}"/>
            				<Image Source="/MALRECrewrite;component/Etc/Flags/gb.png" HorizontalAlignment="Left" VerticalAlignment="Top" Width="16" Height="11" Margin="0,0,2,0" Visibility="{Binding IsEnglish, Converter={StaticResource BooleanToVisibilityConverter}}"/>
            				<Image Source="/MALRECrewrite;component/Etc/Flags/jp.png" HorizontalAlignment="Left" VerticalAlignment="Top" Width="16" Height="11" Margin="0,0,2,0" Visibility="{Binding IsJapanese, Converter={StaticResource BooleanToVisibilityConverter}}"/>
            				<Image Source="/MALRECrewrite;component/Etc/Flags/u.png" HorizontalAlignment="Left" VerticalAlignment="Top" Width="16" Height="11" Visibility="{Binding LangUnknown, Converter={StaticResource BooleanToVisibilityConverter}}"/>
            			</StackPanel>
            		</Border>
            		<Grid Margin="0" Grid.Column="1" Background="{DynamicResource HighlightBrush}">
            			<ListBox ItemTemplate="{DynamicResource StringTemplate1}" ItemsSource="{Binding Sources}" Margin="0" Background="{x:Null}" BorderBrush="{x:Null}" Foreground="White" ScrollViewer.HorizontalScrollBarVisibility="Hidden" ScrollViewer.VerticalScrollBarVisibility="Hidden" FontSize="10.667"/>
            		</Grid>
            	</Grid>
            </Border>
        </DataTemplate>
        <SolidColorBrush x:Key="CheckBoxFillNormal" Color="#F4F4F4"/>
        <SolidColorBrush x:Key="CheckBoxStroke" Color="#8E8F8F"/>
        <Style x:Key="EmptyCheckBoxFocusVisual">
            <Setter Property="Control.Template">
                <Setter.Value>
                    <ControlTemplate>
                        <Rectangle Margin="1" SnapsToDevicePixels="true" Stroke="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}" StrokeThickness="1" StrokeDashArray="1 2"/>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <Style x:Key="SliderCheckbox" TargetType="{x:Type CheckBox}">
            <Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}"/>
            <Setter Property="Background" Value="{StaticResource CheckBoxFillNormal}"/>
            <Setter Property="BorderBrush" Value="{StaticResource CheckBoxStroke}"/>
            <Setter Property="BorderThickness" Value="1"/>
            <Setter Property="FocusVisualStyle" Value="{StaticResource EmptyCheckBoxFocusVisual}"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="{x:Type CheckBox}">
                        <Grid Height="Auto" Width="Auto" Background="#00000000" VerticalAlignment="Center">
                            <VisualStateManager.VisualStateGroups>
                                <VisualStateGroup x:Name="CheckStates">
                                    <VisualStateGroup.Transitions>
                                        <VisualTransition GeneratedDuration="0" To="Checked">
                                            <Storyboard>
                                                <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" Storyboard.TargetName="regularPolygon">
                                                    <EasingDoubleKeyFrame KeyTime="0" Value="90"/>
                                                    <EasingDoubleKeyFrame KeyTime="0:0:0.5" Value="-90"/>
                                                </DoubleAnimationUsingKeyFrames>
                                            </Storyboard>
                                        </VisualTransition>
                                        <VisualTransition From="Checked" GeneratedDuration="0">
                                            <Storyboard>
                                                <DoubleAnimation Duration="0:0:0.5" To="90" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" Storyboard.TargetName="regularPolygon"/>
                                            </Storyboard>
                                        </VisualTransition>
                                    </VisualStateGroup.Transitions>
                                    <VisualState x:Name="Checked">
                                        <Storyboard>
                                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" Storyboard.TargetName="regularPolygon">
                                                <EasingDoubleKeyFrame KeyTime="0" Value="-90"/>
                                            </DoubleAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Unchecked"/>
                                    <VisualState x:Name="Indeterminate"/>
                                </VisualStateGroup>
                            </VisualStateManager.VisualStateGroups>
                            <Canvas x:Name="canvas" Margin="0" VerticalAlignment="Center" Height="25" ClipToBounds="True" Width="9" HorizontalAlignment="Left">
                                <Rectangle Fill="White" Height="21" Stroke="Black" Width="16" RadiusX="52" RadiusY="9" Margin="0" VerticalAlignment="Center" Canvas.Left="-7.375" Canvas.Top="2.375"/>
                                <ed:RegularPolygon x:Name="regularPolygon" Fill="White" Height="5" InnerRadius="1" PointCount="3" Stretch="Fill" Stroke="Black" Width="5" RenderTransformOrigin="0.5,0.5" Margin="0" VerticalAlignment="Center" Canvas.Left="0.125" Canvas.Top="10.375">
                                    <ed:RegularPolygon.RenderTransform>
                                        <TransformGroup>
                                            <ScaleTransform/>
                                            <SkewTransform/>
                                            <RotateTransform Angle="90"/>
                                            <TranslateTransform/>
                                        </TransformGroup>
                                    </ed:RegularPolygon.RenderTransform>
                                </ed:RegularPolygon>
                            </Canvas>
                        </Grid>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <Style x:Key="AnimeCheckbox" TargetType="{x:Type CheckBox}">
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="{x:Type CheckBox}">
                        <Grid>
                            <VisualStateManager.VisualStateGroups>
                                <VisualStateGroup x:Name="CheckStates">
                                    <VisualState x:Name="Checked"/>
                                    <VisualState x:Name="Unchecked">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="textBlock">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{x:Static Visibility.Visible}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="textBlock1">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{x:Static Visibility.Hidden}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Indeterminate"/>
                                </VisualStateGroup>
                            </VisualStateManager.VisualStateGroups>
                            <TextBlock x:Name="textBlock1" TextWrapping="Wrap" Text="{TemplateBinding Content}" />
                            <TextBlock x:Name="textBlock" TextWrapping="Wrap" Text="{TemplateBinding Content}" Visibility="Hidden" >
								<TextBlock.TextDecorations>
    								<TextDecoration Location="Strikethrough">
      									<TextDecoration.Pen>
        									<Pen Brush="Black" />
										</TextDecoration.Pen>
    								</TextDecoration>
  								</TextBlock.TextDecorations>
                            </TextBlock>
                        </Grid>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <SolidColorBrush x:Key="ListBorder" Color="#828790"/>
        <Style x:Key="ListBoxStyle1" TargetType="{x:Type ListBox}">
            <Setter Property="Background" Value="{DynamicResource {x:Static SystemColors.WindowBrushKey}}"/>
            <Setter Property="BorderBrush" Value="{StaticResource ListBorder}"/>
            <Setter Property="BorderThickness" Value="1"/>
            <Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}"/>
            <Setter Property="ScrollViewer.HorizontalScrollBarVisibility" Value="Auto"/>
            <Setter Property="ScrollViewer.VerticalScrollBarVisibility" Value="Auto"/>
            <Setter Property="ScrollViewer.CanContentScroll" Value="true"/>
            <Setter Property="ScrollViewer.PanningMode" Value="Both"/>
            <Setter Property="Stylus.IsFlicksEnabled" Value="False"/>
            <Setter Property="VerticalContentAlignment" Value="Center"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="{x:Type ListBox}">
                        <Grid x:Name="Bd" Background="{TemplateBinding Background}" SnapsToDevicePixels="true" >
                            <ScrollViewer Focusable="false" Padding="{TemplateBinding Padding}" Margin="0">
                                <ItemsPresenter SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"/>
                            </ScrollViewer>
                        </Grid>
                        <ControlTemplate.Triggers>
                            <Trigger Property="IsEnabled" Value="false"/>
                            <Trigger Property="IsGrouping" Value="true">
                                <Setter Property="ScrollViewer.CanContentScroll" Value="false"/>
                            </Trigger>
                        </ControlTemplate.Triggers>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <Style x:Key="MetroProgressbar" TargetType="{x:Type ProgressBar}">
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="{x:Type ProgressBar}">
                        <Canvas>
                            <VisualStateManager.VisualStateGroups>
                                <VisualStateGroup x:Name="CommonStates">
                                    <VisualState x:Name="Determinate"/>
                                    <VisualState x:Name="Indeterminate">
                                        <Storyboard RepeatBehavior="Forever">
                                            <ThicknessAnimationUsingKeyFrames Storyboard.TargetProperty="(FrameworkElement.Margin)" Storyboard.TargetName="rectangle">
                                                <EasingThicknessKeyFrame KeyTime="0" Value="0"/>
                                                <EasingThicknessKeyFrame KeyTime="0:0:0.5" Value="312,0,0,0">
                                                    <EasingThicknessKeyFrame.EasingFunction>
                                                        <ExponentialEase EasingMode="EaseOut"/>
                                                    </EasingThicknessKeyFrame.EasingFunction>
                                                </EasingThicknessKeyFrame>
                                                <EasingThicknessKeyFrame KeyTime="0:0:1" Value="625,0,0,0">
                                                    <EasingThicknessKeyFrame.EasingFunction>
                                                        <ExponentialEase EasingMode="EaseIn"/>
                                                    </EasingThicknessKeyFrame.EasingFunction>
                                                </EasingThicknessKeyFrame>
                                            </ThicknessAnimationUsingKeyFrames>
                                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="rectangle">
                                                <EasingDoubleKeyFrame KeyTime="0" Value="0"/>
                                                <EasingDoubleKeyFrame KeyTime="0:0:0.2" Value="1"/>
                                                <EasingDoubleKeyFrame KeyTime="0:0:0.8" Value="1"/>
                                                <EasingDoubleKeyFrame KeyTime="0:0:1" Value="0"/>
                                            </DoubleAnimationUsingKeyFrames>
                                            <ThicknessAnimationUsingKeyFrames Storyboard.TargetProperty="(FrameworkElement.Margin)" Storyboard.TargetName="rectangle_Copy">
                                                <EasingThicknessKeyFrame KeyTime="0:0:0.1" Value="0"/>
                                                <EasingThicknessKeyFrame KeyTime="0:0:0.6" Value="312,0,0,0">
                                                    <EasingThicknessKeyFrame.EasingFunction>
                                                        <ExponentialEase EasingMode="EaseOut"/>
                                                    </EasingThicknessKeyFrame.EasingFunction>
                                                </EasingThicknessKeyFrame>
                                                <EasingThicknessKeyFrame KeyTime="0:0:1.1" Value="625,0,0,0">
                                                    <EasingThicknessKeyFrame.EasingFunction>
                                                        <ExponentialEase EasingMode="EaseIn"/>
                                                    </EasingThicknessKeyFrame.EasingFunction>
                                                </EasingThicknessKeyFrame>
                                            </ThicknessAnimationUsingKeyFrames>
                                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="rectangle_Copy">
                                                <EasingDoubleKeyFrame KeyTime="0:0:0.1" Value="0"/>
                                                <EasingDoubleKeyFrame KeyTime="0:0:0.3" Value="1"/>
                                                <EasingDoubleKeyFrame KeyTime="0:0:0.9" Value="1"/>
                                                <EasingDoubleKeyFrame KeyTime="0:0:1.1" Value="0"/>
                                            </DoubleAnimationUsingKeyFrames>
                                            <ThicknessAnimationUsingKeyFrames Storyboard.TargetProperty="(FrameworkElement.Margin)" Storyboard.TargetName="rectangle_Copy1">
                                                <EasingThicknessKeyFrame KeyTime="0:0:0.2" Value="0"/>
                                                <EasingThicknessKeyFrame KeyTime="0:0:0.7" Value="312,0,0,0">
                                                    <EasingThicknessKeyFrame.EasingFunction>
                                                        <ExponentialEase EasingMode="EaseOut"/>
                                                    </EasingThicknessKeyFrame.EasingFunction>
                                                </EasingThicknessKeyFrame>
                                                <EasingThicknessKeyFrame KeyTime="0:0:1.2" Value="625,0,0,0">
                                                    <EasingThicknessKeyFrame.EasingFunction>
                                                        <ExponentialEase EasingMode="EaseIn"/>
                                                    </EasingThicknessKeyFrame.EasingFunction>
                                                </EasingThicknessKeyFrame>
                                            </ThicknessAnimationUsingKeyFrames>
                                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="rectangle_Copy1">
                                                <EasingDoubleKeyFrame KeyTime="0:0:0.2" Value="0"/>
                                                <EasingDoubleKeyFrame KeyTime="0:0:0.4" Value="1"/>
                                                <EasingDoubleKeyFrame KeyTime="0:0:1" Value="1"/>
                                                <EasingDoubleKeyFrame KeyTime="0:0:1.2" Value="0"/>
                                            </DoubleAnimationUsingKeyFrames>
                                            <ThicknessAnimationUsingKeyFrames Storyboard.TargetProperty="(FrameworkElement.Margin)" Storyboard.TargetName="rectangle_Copy2">
                                                <EasingThicknessKeyFrame KeyTime="0:0:0.3" Value="0"/>
                                                <EasingThicknessKeyFrame KeyTime="0:0:0.8" Value="312,0,0,0">
                                                    <EasingThicknessKeyFrame.EasingFunction>
                                                        <ExponentialEase EasingMode="EaseOut"/>
                                                    </EasingThicknessKeyFrame.EasingFunction>
                                                </EasingThicknessKeyFrame>
                                                <EasingThicknessKeyFrame KeyTime="0:0:1.3" Value="625,0,0,0">
                                                    <EasingThicknessKeyFrame.EasingFunction>
                                                        <ExponentialEase EasingMode="EaseIn"/>
                                                    </EasingThicknessKeyFrame.EasingFunction>
                                                </EasingThicknessKeyFrame>
                                            </ThicknessAnimationUsingKeyFrames>
                                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="rectangle_Copy2">
                                                <EasingDoubleKeyFrame KeyTime="0:0:0.3" Value="0"/>
                                                <EasingDoubleKeyFrame KeyTime="0:0:0.5" Value="1"/>
                                                <EasingDoubleKeyFrame KeyTime="0:0:1.1" Value="1"/>
                                                <EasingDoubleKeyFrame KeyTime="0:0:1.3" Value="0"/>
                                            </DoubleAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                </VisualStateGroup>
                            </VisualStateManager.VisualStateGroups>
                            <Rectangle x:Name="rectangle" Fill="{DynamicResource HighlightBrush}" Height="10" Width="10" Margin="0" Opacity="0"/>
                            <Rectangle x:Name="rectangle_Copy" Fill="{DynamicResource HighlightBrush}" Height="10" Width="10" Margin="0" Opacity="0"/>
                            <Rectangle x:Name="rectangle_Copy1" Fill="{DynamicResource HighlightBrush}" Height="10" Width="10" Margin="0" Opacity="0"/>
                            <Rectangle x:Name="rectangle_Copy2" Fill="{DynamicResource HighlightBrush}" Height="10" Width="10" Margin="0" Opacity="0"/>
                        </Canvas>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <Style x:Key="ListBoxItemStyle1" TargetType="{x:Type ListBoxItem}">
            <EventSetter Event="Control.MouseDoubleClick" Handler="ListBoxItem_DoubleClick" />
            <Setter Property="Background" Value="Transparent"/>
            <Setter Property="HorizontalContentAlignment" Value="{Binding HorizontalContentAlignment, RelativeSource={RelativeSource AncestorType={x:Type ItemsControl}}}"/>
            <Setter Property="VerticalContentAlignment" Value="{Binding VerticalContentAlignment, RelativeSource={RelativeSource AncestorType={x:Type ItemsControl}}}"/>
            <Setter Property="Padding" Value="2,0,0,0"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="{x:Type ListBoxItem}">
                        <Border x:Name="Bd" Background="{TemplateBinding Background}" Padding="{TemplateBinding Padding}" SnapsToDevicePixels="true" BorderThickness="1" BorderBrush="#00000000">
                        	<Border.ContextMenu>
                        		<ContextMenu>
                        			<MenuItem Header="Blacklist" Click="MenuItem_Click"/>
                        		</ContextMenu>
                        	</Border.ContextMenu>
                            <Border.Effect>
                                <DropShadowEffect BlurRadius="0" Direction="261" ShadowDepth="0"/>
                            </Border.Effect>
                            <ContentPresenter HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}"/>
                        </Border>
                        <ControlTemplate.Triggers>
                            <Trigger Property="IsSelected" Value="true">
                                <Setter Property="Effect" TargetName="Bd">
                                    <Setter.Value>
                                        <DropShadowEffect BlurRadius="28" Direction="261" ShadowDepth="0"/>
                                    </Setter.Value>
                                </Setter>
                                <Setter Property="BorderBrush" TargetName="Bd" Value="Black"/>
                            </Trigger>
                        </ControlTemplate.Triggers>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <DataTemplate x:Key="StringTemplate">
            <StackPanel>
                <CheckBox Content="{Binding Name}" IsChecked="{Binding IsEnabled}"/>
            </StackPanel>
        </DataTemplate>
        <DataTemplate x:Key="DataTemplate1">
            <StackPanel>
            	<CheckBox Content="{Binding Title}" IsChecked="{Binding IsActive}"/>
            </StackPanel>
        </DataTemplate>
        <Storyboard x:Key="WebbrowserSiteChangedAnimationStart" AutoReverse="False">
            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.X)" Storyboard.TargetName="webBrowser">
                <EasingDoubleKeyFrame KeyTime="0:0:0.4" Value="330">
                    <EasingDoubleKeyFrame.EasingFunction>
                        <CircleEase EasingMode="EaseIn"/>
                    </EasingDoubleKeyFrame.EasingFunction>
                </EasingDoubleKeyFrame>
            </DoubleAnimationUsingKeyFrames>
            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="webBrowser">
                <EasingDoubleKeyFrame KeyTime="0:0:0.4" Value="0"/>
            </DoubleAnimationUsingKeyFrames>
        </Storyboard>
        <Storyboard x:Key="WebbrowserSiteChangedAnimationEnd" AutoReverse="False">
            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.X)" Storyboard.TargetName="webBrowser">
                <EasingDoubleKeyFrame KeyTime="0:0:0.4" Value="0"/>
            </DoubleAnimationUsingKeyFrames>
            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="webBrowser">
                <EasingDoubleKeyFrame KeyTime="0:0:0.4" Value="1"/>
            </DoubleAnimationUsingKeyFrames>
        </Storyboard>
        <Style x:Key="ButtonFocusVisual">
            <Setter Property="Control.Template">
                <Setter.Value>
                    <ControlTemplate>
                        <Rectangle Margin="2" SnapsToDevicePixels="true" Stroke="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}" StrokeThickness="1" StrokeDashArray="1 2"/>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <LinearGradientBrush x:Key="ButtonNormalBackground" EndPoint="0,1" StartPoint="0,0">
            <GradientStop Color="#F3F3F3" Offset="0"/>
            <GradientStop Color="#EBEBEB" Offset="0.5"/>
            <GradientStop Color="#DDDDDD" Offset="0.5"/>
            <GradientStop Color="#CDCDCD" Offset="1"/>
        </LinearGradientBrush>
        <SolidColorBrush x:Key="ButtonNormalBorder" Color="#FF707070"/>
        <Style x:Key="SimpleButton" TargetType="{x:Type Button}">
            <Setter Property="FocusVisualStyle" Value="{StaticResource ButtonFocusVisual}"/>
            <Setter Property="Background" Value="{StaticResource ButtonNormalBackground}"/>
            <Setter Property="BorderBrush" Value="{StaticResource ButtonNormalBorder}"/>
            <Setter Property="BorderThickness" Value="1"/>
            <Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}"/>
            <Setter Property="HorizontalContentAlignment" Value="Center"/>
            <Setter Property="VerticalContentAlignment" Value="Center"/>
            <Setter Property="Padding" Value="1"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="{x:Type Button}">
                        <Grid HorizontalAlignment="Left" Height="Auto" VerticalAlignment="Top">
                            <VisualStateManager.VisualStateGroups>
                                <VisualStateGroup x:Name="CommonStates">
                                    <VisualStateGroup.Transitions>
                                        <VisualTransition GeneratedDuration="0:0:0.2" To="MouseOver">
                                            <VisualTransition.GeneratedEasingFunction>
                                                <CircleEase EasingMode="EaseOut"/>
                                            </VisualTransition.GeneratedEasingFunction>
                                        </VisualTransition>
                                        <VisualTransition GeneratedDuration="0:0:0.05" To="Pressed">
                                            <Storyboard>
                                                <ColorAnimation Duration="0:0:0.05" To="White" Storyboard.TargetProperty="(TextElement.Foreground).(SolidColorBrush.Color)" Storyboard.TargetName="textBlock"/>
                                                <DoubleAnimation Duration="0:0:0.05" To="0" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)" Storyboard.TargetName="border"/>
                                                <DoubleAnimation Duration="0:0:0.05" To="1" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleX)" Storyboard.TargetName="textBlock"/>
                                                <DoubleAnimation Duration="0:0:0.05" To="1.1" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleX)" Storyboard.TargetName="border1"/>
                                                <DoubleAnimation Duration="0:0:0.05" To="1.1" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleY)" Storyboard.TargetName="border1"/>
                                            </Storyboard>
                                        </VisualTransition>
                                        <VisualTransition From="Pressed" GeneratedDuration="0:0:0.05"/>
                                    </VisualStateGroup.Transitions>
                                    <VisualState x:Name="Normal"/>
                                    <VisualState x:Name="MouseOver">
                                        <Storyboard>
                                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)" Storyboard.TargetName="border">
                                                <EasingDoubleKeyFrame KeyTime="0" Value="0"/>
                                            </DoubleAnimationUsingKeyFrames>
                                            <ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(TextElement.Foreground).(SolidColorBrush.Color)" Storyboard.TargetName="textBlock">
                                                <EasingColorKeyFrame KeyTime="0" Value="White"/>
                                            </ColorAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Pressed">
                                        <Storyboard>
                                            <ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(TextElement.Foreground).(SolidColorBrush.Color)" Storyboard.TargetName="textBlock">
                                                <EasingColorKeyFrame KeyTime="0" Value="White"/>
                                            </ColorAnimationUsingKeyFrames>
                                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)" Storyboard.TargetName="border">
                                                <EasingDoubleKeyFrame KeyTime="0" Value="0"/>
                                            </DoubleAnimationUsingKeyFrames>
                                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleX)" Storyboard.TargetName="textBlock">
                                                <EasingDoubleKeyFrame KeyTime="0" Value="1"/>
                                            </DoubleAnimationUsingKeyFrames>
                                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleX)" Storyboard.TargetName="border1">
                                                <EasingDoubleKeyFrame KeyTime="0" Value="1.1"/>
                                            </DoubleAnimationUsingKeyFrames>
                                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleY)" Storyboard.TargetName="border1">
                                                <EasingDoubleKeyFrame KeyTime="0" Value="1.1"/>
                                            </DoubleAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Disabled">
                                    	<Storyboard>
                                    		<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.X)" Storyboard.TargetName="border_Copy">
                                    			<EasingDoubleKeyFrame KeyTime="0" Value="0"/>
                                    		</DoubleAnimationUsingKeyFrames>
                                    	</Storyboard>
                                    </VisualState>
                                </VisualStateGroup>
                            </VisualStateManager.VisualStateGroups>
                            <Border x:Name="border1" BorderBrush="{TemplateBinding Foreground}" BorderThickness="1" Height="Auto" HorizontalAlignment="Stretch" VerticalAlignment="Top" Padding="0" d:LayoutOverrides="Width" Margin="0" RenderTransformOrigin="0.5,0.5">
                                <Border.RenderTransform>
                                    <TransformGroup>
                                        <ScaleTransform/>
                                        <SkewTransform/>
                                        <RotateTransform/>
                                        <TranslateTransform/>
                                    </TransformGroup>
                                </Border.RenderTransform>
                                <Grid Height="Auto" Width="Auto" ClipToBounds="True">
                                    <Border x:Name="border" BorderThickness="0" Margin="0" Background="{DynamicResource HighlightBrush}" RenderTransformOrigin="0.5,0.5">
                                        <Border.RenderTransform>
                                            <TransformGroup>
                                                <ScaleTransform/>
                                                <SkewTransform/>
                                                <RotateTransform/>
                                                <TranslateTransform Y="{Binding ActualHeight, RelativeSource={RelativeSource TemplatedParent}}"/>
                                            </TransformGroup>
                                        </Border.RenderTransform>
                                    </Border>
                                    <TextBlock x:Name="textBlock" Margin="2" TextWrapping="Wrap" Text="{TemplateBinding Content}" d:LayoutOverrides="Width, Height" FontFamily="{TemplateBinding FontFamily}" FontSize="{TemplateBinding FontSize}" RenderTransformOrigin="0.5,0.5">
    									<TextBlock.RenderTransform>
    										<TransformGroup>
    											<ScaleTransform/>
    											<SkewTransform/>
    											<RotateTransform/>
    											<TranslateTransform/>
    										</TransformGroup>
    									</TextBlock.RenderTransform>
                                    </TextBlock>
                                    <Border x:Name="border_Copy" BorderThickness="0" Margin="0" Background="{DynamicResource HighlightBrush}" RenderTransformOrigin="0.5,0.5">
                                    	<Border.RenderTransform>
                                    		<TransformGroup>
                                    			<ScaleTransform/>
                                    			<SkewTransform/>
                                    			<RotateTransform/>
                                    			<TranslateTransform X="{Binding ActualWidth, RelativeSource={RelativeSource TemplatedParent}}"/>
                                    		</TransformGroup>
                                    	</Border.RenderTransform>
                                    </Border>
                                </Grid>
                            </Border>
                        </Grid>
                        <ControlTemplate.Triggers>
                            <Trigger Property="IsKeyboardFocused" Value="true"/>
                            <Trigger Property="ToggleButton.IsChecked" Value="true"/>
                            <Trigger Property="IsEnabled" Value="false">
                                <Setter Property="Foreground" Value="#ADADAD"/>
                            </Trigger>
                        </ControlTemplate.Triggers>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <LinearGradientBrush x:Key="ProgressBarBackground" EndPoint="1,0" StartPoint="0,0">
        	<GradientStop Color="#BABABA" Offset="0"/>
        	<GradientStop Color="#C7C7C7" Offset="0.5"/>
        	<GradientStop Color="#BABABA" Offset="1"/>
        </LinearGradientBrush>
        <LinearGradientBrush x:Key="ProgressBarBorderBrush" EndPoint="0,1" StartPoint="0,0">
        	<GradientStop Color="#B2B2B2" Offset="0"/>
        	<GradientStop Color="#8C8C8C" Offset="1"/>
        </LinearGradientBrush>
        <LinearGradientBrush x:Key="ProgressBarGlassyHighlight" EndPoint="0,1" StartPoint="0,0">
        	<GradientStop Color="#50FFFFFF" Offset="0.5385"/>
        	<GradientStop Color="#00FFFFFF" Offset="0.5385"/>
        </LinearGradientBrush>
        <LinearGradientBrush x:Key="ProgressBarTopHighlight" EndPoint="0,1" StartPoint="0,0">
        	<GradientStop Color="#80FFFFFF" Offset="0.05"/>
        	<GradientStop Color="#00FFFFFF" Offset="0.25"/>
        </LinearGradientBrush>
        <LinearGradientBrush x:Key="ProgressBarIndicatorAnimatedFill" EndPoint="1,0" StartPoint="0,0">
        	<GradientStop Color="#00FFFFFF" Offset="0"/>
        	<GradientStop Color="#60FFFFFF" Offset="0.4"/>
        	<GradientStop Color="#60FFFFFF" Offset="0.6"/>
        	<GradientStop Color="#00FFFFFF" Offset="1"/>
        </LinearGradientBrush>
        <LinearGradientBrush x:Key="ProgressBarIndicatorDarkEdgeLeft" EndPoint="1,0" StartPoint="0,0">
        	<GradientStop Color="#0C000000" Offset="0"/>
        	<GradientStop Color="#20000000" Offset="0.3"/>
        	<GradientStop Color="#00000000" Offset="1"/>
        </LinearGradientBrush>
        <LinearGradientBrush x:Key="ProgressBarIndicatorDarkEdgeRight" EndPoint="1,0" StartPoint="0,0">
        	<GradientStop Color="#00000000" Offset="0"/>
        	<GradientStop Color="#20000000" Offset="0.7"/>
        	<GradientStop Color="#0C000000" Offset="1"/>
        </LinearGradientBrush>
        <RadialGradientBrush x:Key="ProgressBarIndicatorLightingEffectLeft" RadiusY="1" RadiusX="1" RelativeTransform="1,0,0,1,0.5,0.5">
        	<GradientStop Color="#60FFFFC4" Offset="0"/>
        	<GradientStop Color="#00FFFFC4" Offset="1"/>
        </RadialGradientBrush>
        <LinearGradientBrush x:Key="ProgressBarIndicatorLightingEffect" EndPoint="0,0" StartPoint="0,1">
        	<GradientStop Color="#60FFFFC4" Offset="0"/>
        	<GradientStop Color="#00FFFFC4" Offset="1"/>
        </LinearGradientBrush>
        <RadialGradientBrush x:Key="ProgressBarIndicatorLightingEffectRight" RadiusY="1" RadiusX="1" RelativeTransform="1,0,0,1,-0.5,0.5">
        	<GradientStop Color="#60FFFFC4" Offset="0"/>
        	<GradientStop Color="#00FFFFC4" Offset="1"/>
        </RadialGradientBrush>
        <LinearGradientBrush x:Key="ProgressBarIndicatorGlassyHighlight" EndPoint="0,1" StartPoint="0,0">
        	<GradientStop Color="#90FFFFFF" Offset="0.5385"/>
        	<GradientStop Color="#00FFFFFF" Offset="0.5385"/>
        </LinearGradientBrush>
        <Style x:Key="ProgressBarStyle1" TargetType="{x:Type ProgressBar}">
        	<Setter Property="Foreground" Value="#01D328"/>
        	<Setter Property="Background" Value="{StaticResource ProgressBarBackground}"/>
        	<Setter Property="BorderBrush" Value="{StaticResource ProgressBarBorderBrush}"/>
        	<Setter Property="BorderThickness" Value="1"/>
        	<Setter Property="Template">
        		<Setter.Value>
        			<ControlTemplate TargetType="{x:Type ProgressBar}">
        				<Grid x:Name="TemplateRoot" SnapsToDevicePixels="true">
        					<Rectangle Fill="{TemplateBinding Background}" RadiusY="2" RadiusX="2"/>
        					<Border Background="{StaticResource ProgressBarGlassyHighlight}" CornerRadius="2" Margin="1"/>
        					<Border BorderBrush="#80FFFFFF" BorderThickness="1,0,1,1" Background="{StaticResource ProgressBarTopHighlight}" Margin="1"/>
        					<Rectangle x:Name="PART_Track" Margin="1"/>
        					<TextBlock HorizontalAlignment="Left" Margin="1,0,0,0" TextWrapping="NoWrap" Text="{TemplateBinding Tag}" Foreground="Black" FontSize="12" VerticalAlignment="Center"/>
        					<Decorator x:Name="PART_Indicator" HorizontalAlignment="Left" Margin="1">
        						<Grid x:Name="Foreground">
        							<Rectangle x:Name="Indicator" Fill="{TemplateBinding Foreground}"/>
        							<TextBlock HorizontalAlignment="Left" Margin="1,0,0,0" TextWrapping="NoWrap" Text="{TemplateBinding Tag}" d:LayoutOverrides="Width" Foreground="White" FontSize="12" VerticalAlignment="Center"/>
        						</Grid>
        					</Decorator>
        					<Border BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="0" BorderBrush="{TemplateBinding Foreground}"/>
        				</Grid>
        				<ControlTemplate.Triggers>
        					<Trigger Property="Orientation" Value="Vertical">
        						<Setter Property="LayoutTransform" TargetName="TemplateRoot">
        							<Setter.Value>
        								<RotateTransform Angle="-90"/>
        							</Setter.Value>
        						</Setter>
        					</Trigger>
        					<Trigger Property="IsIndeterminate" Value="true">
        						<Setter Property="Visibility" TargetName="Indicator" Value="Collapsed"/>
        					</Trigger>
        					<Trigger Property="IsIndeterminate" Value="false"/>
        				</ControlTemplate.Triggers>
        			</ControlTemplate>
        		</Setter.Value>
        	</Setter>
        </Style>
        <Style x:Key="ButtonStyle1" TargetType="{x:Type Button}">
        	<Setter Property="Template">
        		<Setter.Value>
        			<ControlTemplate TargetType="{x:Type Button}">
        				<Grid>
        					<ContentPresenter RecognizesAccessKey="True" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"/>
        				</Grid>
        				<ControlTemplate.Triggers>
        					<Trigger Property="IsFocused" Value="True"/>
        					<Trigger Property="IsDefaulted" Value="True"/>
        					<Trigger Property="IsMouseOver" Value="True"/>
        					<Trigger Property="IsPressed" Value="True"/>
        					<Trigger Property="IsEnabled" Value="False"/>
        				</ControlTemplate.Triggers>
        			</ControlTemplate>
        		</Setter.Value>
        	</Setter>
        	<Setter Property="Foreground" Value="White"/>
        </Style>
        <DataTemplate x:Key="StringTemplate1">
        	<StackPanel>
        		<TextBlock Text="{Binding Mode=OneWay}"/>
        	</StackPanel>
        </DataTemplate>
        <Storyboard x:Key="ShowMessageAnimation" AutoReverse="True">
        	<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleX)" Storyboard.TargetName="grid2">
        		<EasingDoubleKeyFrame KeyTime="0" Value="1">
        			<EasingDoubleKeyFrame.EasingFunction>
        				<BackEase EasingMode="EaseIn"/>
        			</EasingDoubleKeyFrame.EasingFunction>
        		</EasingDoubleKeyFrame>
        		<EasingDoubleKeyFrame KeyTime="0:0:0.3" Value="1.25">
        			<EasingDoubleKeyFrame.EasingFunction>
        				<BackEase EasingMode="EaseIn"/>
        			</EasingDoubleKeyFrame.EasingFunction>
        		</EasingDoubleKeyFrame>
        	</DoubleAnimationUsingKeyFrames>
        	<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleY)" Storyboard.TargetName="grid2">
        		<EasingDoubleKeyFrame KeyTime="0" Value="1">
        			<EasingDoubleKeyFrame.EasingFunction>
        				<BackEase EasingMode="EaseIn"/>
        			</EasingDoubleKeyFrame.EasingFunction>
        		</EasingDoubleKeyFrame>
        		<EasingDoubleKeyFrame KeyTime="0:0:0.3" Value="1.25">
        			<EasingDoubleKeyFrame.EasingFunction>
        				<BackEase EasingMode="EaseIn"/>
        			</EasingDoubleKeyFrame.EasingFunction>
        		</EasingDoubleKeyFrame>
        	</DoubleAnimationUsingKeyFrames>
        </Storyboard>
        <HierarchicalDataTemplate  x:Key="CheckBoxItemTemplate" ItemsSource="{Binding Children}">
            <StackPanel Orientation="Horizontal">
                <CheckBox Focusable="False"  IsChecked="{Binding IsChecked}" VerticalAlignment="Center" />
                <ContentPresenter  Content="{Binding Title, Mode=OneTime}" Margin="2,0" />
            </StackPanel>
        </HierarchicalDataTemplate>

    </Window.Resources>
    <Window.Triggers>
        <EventTrigger RoutedEvent="FrameworkElement.Loaded">
            <BeginStoryboard x:Name="WebbrowserSiteChangedAnimationStart_BeginStoryboard" Storyboard="{StaticResource WebbrowserSiteChangedAnimationStart}"/>
            <BeginStoryboard Storyboard="{StaticResource ShowMessageAnimation}"/>
        </EventTrigger>
    </Window.Triggers>
    <Grid>
    	<i:Interaction.Behaviors>
    		<ei:DataStateBehavior Binding="{Binding IsDownloadingData}" Value="True" TrueState="IsLoading" FalseState="IsNotLoading"/>
    	</i:Interaction.Behaviors>
        <VisualStateManager.VisualStateGroups>
            <VisualStateGroup x:Name="LoadingStateGroup">
        		<VisualStateGroup.Transitions>
        			<VisualTransition GeneratedDuration="0"/>
        			<VisualTransition GeneratedDuration="0:0:0.4" To="IsLoading">
        				<VisualTransition.GeneratedEasingFunction>
        					<BackEase EasingMode="EaseOut"/>
        				</VisualTransition.GeneratedEasingFunction>
        				<Storyboard>
        					<ThicknessAnimationUsingKeyFrames Storyboard.TargetProperty="(FrameworkElement.Margin)" Storyboard.TargetName="grid3">
        						<EasingThicknessKeyFrame KeyTime="0:0:0.4" Value="0,30,0,0">
        							<EasingThicknessKeyFrame.EasingFunction>
        								<BackEase EasingMode="EaseOut"/>
        							</EasingThicknessKeyFrame.EasingFunction>
        						</EasingThicknessKeyFrame>
        					</ThicknessAnimationUsingKeyFrames>
        				</Storyboard>
        			</VisualTransition>
        			<VisualTransition From="IsLoading" GeneratedDuration="0:0:0.4">
        				<VisualTransition.GeneratedEasingFunction>
        					<BackEase EasingMode="EaseIn"/>
        				</VisualTransition.GeneratedEasingFunction>
        				<Storyboard>
        					<ThicknessAnimationUsingKeyFrames Storyboard.TargetProperty="(FrameworkElement.Margin)" Storyboard.TargetName="grid3">
        						<EasingThicknessKeyFrame KeyTime="0:0:0.5" Value="0">
        							<EasingThicknessKeyFrame.EasingFunction>
        								<BackEase EasingMode="EaseIn"/>
        							</EasingThicknessKeyFrame.EasingFunction>
        						</EasingThicknessKeyFrame>
        					</ThicknessAnimationUsingKeyFrames>
        				</Storyboard>
        			</VisualTransition>
        		</VisualStateGroup.Transitions>
        		<VisualState x:Name="IsLoading">
        			<Storyboard>
        				<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)" Storyboard.TargetName="uniformGrid">
        					<EasingDoubleKeyFrame KeyTime="0" Value="0"/>
        				</DoubleAnimationUsingKeyFrames>
        				<ThicknessAnimationUsingKeyFrames Storyboard.TargetProperty="(FrameworkElement.Margin)" Storyboard.TargetName="grid3">
        					<EasingThicknessKeyFrame KeyTime="0" Value="0,30,0,0"/>
        				</ThicknessAnimationUsingKeyFrames>
        			</Storyboard>
        		</VisualState>
        		<VisualState x:Name="IsNotLoading"/>
        	</VisualStateGroup>
            <VisualStateGroup x:Name="VisualStates"/>
            <VisualStateGroup x:Name="SettingsLoadingStates">
                <VisualStateGroup.Transitions>
                    <VisualTransition From="LoadingSettings" GeneratedDuration="0">
                        <Storyboard>
                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="grid">
                                <EasingDoubleKeyFrame KeyTime="0" Value="1"/>
                                <EasingDoubleKeyFrame KeyTime="0:0:0.2" Value="0"/>
                            </DoubleAnimationUsingKeyFrames>
                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="grid">
                                <DiscreteObjectKeyFrame KeyTime="0:0:0.2" Value="{x:Static Visibility.Visible}"/>
                                <DiscreteObjectKeyFrame KeyTime="0:0:0.3" Value="{x:Static Visibility.Hidden}"/>
                            </ObjectAnimationUsingKeyFrames>
                        </Storyboard>
                    </VisualTransition>
                </VisualStateGroup.Transitions>
                <VisualState x:Name="LoadingSettings">
                    <Storyboard>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="grid">
                            <DiscreteObjectKeyFrame KeyTime="0" Value="{x:Static Visibility.Visible}"/>
                        </ObjectAnimationUsingKeyFrames>
                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="grid">
                            <EasingDoubleKeyFrame KeyTime="0" Value="0.95"/>
                        </DoubleAnimationUsingKeyFrames>
                    </Storyboard>
                </VisualState>
                <VisualState x:Name="NotLoadingSettings">
                    <Storyboard>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(ToggleButton.IsChecked)" Storyboard.TargetName="LeftColumSlider">
                            <DiscreteObjectKeyFrame KeyTime="0">
                                <DiscreteObjectKeyFrame.Value>
                                    <System:Boolean>False</System:Boolean>
                                </DiscreteObjectKeyFrame.Value>
                            </DiscreteObjectKeyFrame>
                        </ObjectAnimationUsingKeyFrames>
                    </Storyboard>
                </VisualState>
            </VisualStateGroup>
            <VisualStateGroup x:Name="BrowserStates">
                <VisualStateGroup.Transitions>
                    <VisualTransition GeneratedDuration="0" To="AnimeSelected">
                        <Storyboard>
                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="grid1">
                                <EasingDoubleKeyFrame KeyTime="0" Value="1"/>
                                <EasingDoubleKeyFrame KeyTime="0:0:0.3" Value="0"/>
                            </DoubleAnimationUsingKeyFrames>
                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="grid1">
                                <DiscreteObjectKeyFrame KeyTime="0:0:0.3" Value="{x:Static Visibility.Visible}"/>
                                <DiscreteObjectKeyFrame KeyTime="0:0:0.4" Value="{x:Static Visibility.Hidden}"/>
                            </ObjectAnimationUsingKeyFrames>
                        </Storyboard>
                    </VisualTransition>
                </VisualStateGroup.Transitions>
                <VisualState x:Name="AnimeSelected">
                    <Storyboard>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="grid1">
                            <DiscreteObjectKeyFrame KeyTime="0" Value="{x:Static Visibility.Hidden}"/>
                        </ObjectAnimationUsingKeyFrames>
                    </Storyboard>
                </VisualState>
                <VisualState x:Name="NoAnimeSelected"/>
            </VisualStateGroup>
        </VisualStateManager.VisualStateGroups>
        <Grid.ColumnDefinitions>
            <ColumnDefinition x:Name="col1"/>
            <ColumnDefinition Width="2*" x:Name="col2"/>
            <ColumnDefinition x:Name="col3" Width="9"/>
        </Grid.ColumnDefinitions>
        <Grid>
            <StackPanel Margin="0,0,9,0" d:LayoutOverrides="Height">
                <StackPanel HorizontalAlignment="Left" Orientation="Horizontal" Margin="2,2,0,2">
            		<Button Content="Update" VerticalAlignment="Top" d:LayoutOverrides="GridBox" Style="{DynamicResource SimpleButton}" Click="UpdateAnimesButton_Click" Margin="0,0,2,0" />
            		<Button Content="Reload" Click="LoadAnimesButton_Click" VerticalAlignment="Top" Style="{DynamicResource SimpleButton}" Margin="0,0,2,0"/>
            		<Button Content="Sequels" VerticalAlignment="Top" Style="{DynamicResource SimpleButton}" Margin="10,0,0,0" Name="squelsButton" Click="squelsButton_Click" />
            	</StackPanel>
                <Expander Header="Genres">
                    <Grid Background="White" VerticalAlignment="Top" MaxHeight="400">
                        <Grid.RowDefinitions>
                            <RowDefinition/>
                            <RowDefinition Height="Auto"/>
                        </Grid.RowDefinitions>
                        <ListBox ItemTemplate="{DynamicResource StringTemplate}" ItemsSource="{Binding Genres}" Margin="0" ScrollViewer.HorizontalScrollBarVisibility="Hidden" ScrollViewer.VerticalScrollBarVisibility="Hidden" d:LayoutOverrides="Height"/>
                        <StackPanel HorizontalAlignment="Right" Margin="0" Orientation="Horizontal" VerticalAlignment="Bottom" Grid.Row="1">
                            <ComboBox SelectedItem="{Binding SelectedGenreMode}" Margin="0,0,5,0" Width="50" HorizontalContentAlignment="Center">
                                <ComboBoxItem Content="and"  />
                                <ComboBoxItem Content="or" IsSelected="True" />
                            </ComboBox>
                            <Button Content="Select All" Margin="0,0,5,0" x:Name="SelectAllButton" Click="SelectAllButton_Click" />
                            <Button Content="Select None" Margin="0,0,5,0" x:Name="SelectNoneButton" Click="SelectNoneButton_Click" />
                            <Button Content="Apply" x:Name="ApplyGenreButton" Click="ApplyGenreButton_Click" d:LayoutOverrides="Width" />
                        </StackPanel>
                    </Grid>
                </Expander>
                <Expander Header="Animes" VerticalAlignment="Top" IsExpanded="True">
                    <Grid VerticalAlignment="Top" MaxHeight="400">
                        <Grid.RowDefinitions>
                        	<RowDefinition Height="Auto"/>
                            <RowDefinition Height="0.869*"/>
                            <RowDefinition Height="Auto"/>
                        </Grid.RowDefinitions>
                        <Button Content="Treeview / Listbox" HorizontalAlignment="Right" Style="{DynamicResource SimpleButton}" VerticalAlignment="Top" Name="TreeViewOrListButton" Click="TreeViewOrListButton_Click" Margin="0,0,0,2" />
                    	<ListBox x:Name="AnimeListbox" ItemTemplate="{DynamicResource DataTemplate1}" ItemsSource="{Binding Animes}" ScrollViewer.HorizontalScrollBarVisibility="Hidden" ScrollViewer.VerticalScrollBarVisibility="Hidden" BorderThickness="1" Margin="0" VerticalAlignment="Top" Visibility="Visible" Grid.Row="1"/>
                        <TreeView ScrollViewer.HorizontalScrollBarVisibility="Hidden" ScrollViewer.VerticalScrollBarVisibility="Hidden" Grid.Row="1"  x:Name="AnimeTreeview"  ItemsSource="{Binding AnimeGroups}" ItemTemplate="{StaticResource CheckBoxItemTemplate}" Visibility="Hidden" />
                        <StackPanel HorizontalAlignment="Right" Margin="0,2,0,0" Orientation="Horizontal" VerticalAlignment="Bottom" Grid.Row="2">
                    		<Button Style="{DynamicResource SimpleButton}" Content="Select All" Margin="0,0,5,0" x:Name="SelectAllAnimesButton" Click="SelectAllAnimesButton_Click" />
                    		<Button Style="{DynamicResource SimpleButton}" Content="Select None" Margin="0,0,5,0" x:Name="SelectNoneAnimesButton" Click="SelectNoneAnimesButton_Click" />
                    		<Button Style="{DynamicResource SimpleButton}" Content="Apply" x:Name="ApplyAnimesButton" d:LayoutOverrides="Width" Click="ApplyAnimesButton_Click" />
                    	</StackPanel>
                    </Grid>
                </Expander>
                <Expander Header="Blacklist" VerticalAlignment="Top">
                	<Grid VerticalAlignment="Top" MaxHeight="400">
                		<Grid.RowDefinitions>
                			<RowDefinition Height="0.869*"/>
                			<RowDefinition Height="Auto"/>
                		</Grid.RowDefinitions>
                		<ListBox ItemTemplate="{DynamicResource DataTemplate1}" ItemsSource="{Binding Blacklist}" ScrollViewer.HorizontalScrollBarVisibility="Hidden" ScrollViewer.VerticalScrollBarVisibility="Hidden" BorderThickness="1" Margin="0" VerticalAlignment="Top" x:Name="BlacklistListbox" />
                		<StackPanel HorizontalAlignment="Right" Margin="0" Orientation="Horizontal" VerticalAlignment="Bottom" Grid.Row="1">
                			<Button Content="Remove" x:Name="RemoveFromBlacklistButton" d:LayoutOverrides="Width" Click="RemoveFromBlacklistButton_Click" />
                		</StackPanel>
                	</Grid>
                </Expander>
            </StackPanel>
        </Grid>
        <CheckBox Content="" Style="{DynamicResource SliderCheckbox}" x:Name="LeftColumSlider" Checked="LeftColumSlider_Checked" Unchecked="LeftColumSlider_Unchecked" Height="25" Width="9" HorizontalAlignment="Right" Margin="0" />
        <Grid x:Name="grid3" Grid.Column="1" d:LayoutOverrides="Height" >
            <ListBox x:Name="listBox" ItemTemplate="{DynamicResource SortedRecommendationTemplate}" ItemsSource="{Binding SortedRecommendations}" Margin="10,5" BorderBrush="{x:Null}" BorderThickness="0" ScrollViewer.HorizontalScrollBarVisibility="Disabled" ScrollViewer.VerticalScrollBarVisibility="Hidden" SelectedItem="{Binding SelectedRecommendation}" SelectionChanged="ListBox_SelectionChanged" ScrollViewer.CanContentScroll="False" d:LayoutOverrides="Height" Style="{DynamicResource ListBoxStyle1}" ItemContainerStyle="{DynamicResource ListBoxItemStyle1}" HorizontalAlignment="Left">
                <ListBox.ItemsPanel>
                    <ItemsPanelTemplate>
                        <WrapPanel IsItemsHost="True" />
                    </ItemsPanelTemplate>
                </ListBox.ItemsPanel>
            </ListBox>
        </Grid>
        <StackPanel Grid.Column="1" HorizontalAlignment="Left" Margin="-9,2,0,0" Orientation="Vertical" VerticalAlignment="Top">
        	<Button Content="⇄" x:Name="ToggleVisualStylesButton" Click="ToggleVisualStylesButton_Click" Style="{DynamicResource SimpleButton}" Margin="0,0,0,2" d:LayoutOverrides="Width" />
        	<Button Content="ü" x:Name="Download10Languages" Style="{DynamicResource SimpleButton}" Margin="0" d:LayoutOverrides="Width" FontFamily="Webdings" Click="Download10Languages_Click" />
        </StackPanel>
        <Grid Grid.Column="2">
            <Border Margin="9,0,0,0" BorderThickness="1,0,0,0" BorderBrush="Black">
                <Grid>
                    <i:Interaction.Behaviors>
                        <ei:DataStateBehavior Binding="{Binding SelectedIndex, ElementName=listBox}" TrueState="NoAnimeSelected" FalseState="AnimeSelected" Value="-1"/>
                    </i:Interaction.Behaviors>
                    <i:Interaction.Triggers>
                        <i:EventTrigger SourceName="webBrowser">
                            <ei:GoToStateAction StateName="NoAnimeSelected"/>
                        </i:EventTrigger>
                    </i:Interaction.Triggers>
                    <my:WebControl x:Name="webBrowser" BeginNavigation="webBrowser_BeginNavigation" RenderTransformOrigin="0.5,0.5" DomReady="webBrowser_DomReady">
                        <my:WebControl.RenderTransform>
                            <TransformGroup>
                                <ScaleTransform/>
                                <SkewTransform/>
                                <RotateTransform/>
                                <TranslateTransform/>
                            </TransformGroup>
                        </my:WebControl.RenderTransform>
                    </my:WebControl>
                    <Grid x:Name="grid1" Margin="0" Background="#F2FFFFFF">
                        <TextBlock TextWrapping="Wrap" Text="No Anime selected..." FontSize="16" HorizontalAlignment="Center" VerticalAlignment="Center"/>
                    </Grid>
                </Grid>
            </Border>
            <CheckBox Content="" Style="{DynamicResource SliderCheckbox}" x:Name="RightColumSlider" RenderTransformOrigin="0.5,0.5" Checked="RightColumSlider_Checked" Unchecked="RightColumSlider_Unchecked" Height="25" Margin="0,285.5">
            	<CheckBox.RenderTransform>
            		<TransformGroup>
            			<ScaleTransform/>
            			<SkewTransform/>
            			<RotateTransform Angle="-180"/>
            			<TranslateTransform/>
            		</TransformGroup>
            	</CheckBox.RenderTransform>
            </CheckBox>
        </Grid>
        <Grid x:Name="grid" Grid.RowSpan="27" Grid.ColumnSpan="40" Background="White" Visibility="Hidden">
            <i:Interaction.Behaviors>
                <ei:DataStateBehavior Binding="{Binding IsLoadingFromSave}" Value="True" TrueState="LoadingSettings" FalseState="NotLoadingSettings"/>
            </i:Interaction.Behaviors>
            <TextBlock HorizontalAlignment="Center" TextWrapping="Wrap" Text="Loading Data from last Save..." VerticalAlignment="Center" FontSize="16"/>
        </Grid>
        <UniformGrid x:Name="uniformGrid" Rows="1" Grid.Column="1" VerticalAlignment="Top" Margin="10,2,10,0" RenderTransformOrigin="0.5,0.5">
        	<UniformGrid.RenderTransform>
        		<TransformGroup>
        			<ScaleTransform/>
        			<SkewTransform/>
        			<RotateTransform/>
        			<TranslateTransform Y="-30"/>
        		</TransformGroup>
        	</UniformGrid.RenderTransform>
        	<ProgressBar Height="20" BorderBrush="{x:Null}" Background="{x:Null}" Style="{DynamicResource ProgressBarStyle1}" VerticalAlignment="Top" Foreground="#FF2E51A2" Margin="0,0,2,0" Maximum="1" Value="{Binding DownloadRecommendationsProgress}" Tag="Recommendations">
        		<i:Interaction.Triggers>
        			<i:EventTrigger EventName="ValueChanged">
        				<i:Interaction.Behaviors>
        					<ei:ConditionBehavior>
        						<ei:ConditionalExpression>
        							<ei:ComparisonCondition LeftOperand="{Binding DownloadRecommendationsProgress}" Operator="GreaterThanOrEqual" RightOperand="1"/>
        						</ei:ConditionalExpression>
        					</ei:ConditionBehavior>
        				</i:Interaction.Behaviors>
        				<ei:ChangePropertyAction PropertyName="Visibility">
        					<ei:ChangePropertyAction.Value>
        						<Visibility>Collapsed</Visibility>
        					</ei:ChangePropertyAction.Value>
        				</ei:ChangePropertyAction>
        			</i:EventTrigger>
        			<i:EventTrigger EventName="ValueChanged">
        				<i:Interaction.Behaviors>
        					<ei:ConditionBehavior>
        						<ei:ConditionalExpression>
        							<ei:ComparisonCondition LeftOperand="{Binding DownloadRecommendationsProgress}" RightOperand="0"/>
        						</ei:ConditionalExpression>
        					</ei:ConditionBehavior>
        				</i:Interaction.Behaviors>
        				<ei:ChangePropertyAction PropertyName="Visibility"/>
        			</i:EventTrigger>
        		</i:Interaction.Triggers>
        	</ProgressBar>
        	<ProgressBar Height="20" BorderBrush="{x:Null}" Background="{x:Null}" Value="{Binding DownloadGenresProgress}" Style="{DynamicResource ProgressBarStyle1}" VerticalAlignment="Top" Margin="0,0,2,0" Maximum="1" Foreground="#FFF30000" Tag="Genres">
        		<i:Interaction.Triggers>
        			<i:EventTrigger EventName="ValueChanged">
        				<i:Interaction.Behaviors>
        					<ei:ConditionBehavior>
        						<ei:ConditionalExpression>
        							<ei:ComparisonCondition LeftOperand="{Binding DownloadGenresProgress}" Operator="GreaterThanOrEqual" RightOperand="1"/>
        						</ei:ConditionalExpression>
        					</ei:ConditionBehavior>
        				</i:Interaction.Behaviors>
        				<ei:ChangePropertyAction PropertyName="Visibility">
        					<ei:ChangePropertyAction.Value>
        						<Visibility>Collapsed</Visibility>
        					</ei:ChangePropertyAction.Value>
        				</ei:ChangePropertyAction>
        			</i:EventTrigger>
        			<i:EventTrigger EventName="ValueChanged">
        				<i:Interaction.Behaviors>
        					<ei:ConditionBehavior>
        						<ei:ConditionalExpression>
        							<ei:ComparisonCondition LeftOperand="{Binding DownloadGenresProgress}" RightOperand="0"/>
        						</ei:ConditionalExpression>
        					</ei:ConditionBehavior>
        				</i:Interaction.Behaviors>
        				<ei:ChangePropertyAction PropertyName="Visibility"/>
        			</i:EventTrigger>
        		</i:Interaction.Triggers>
        	</ProgressBar>
        	<ProgressBar Height="20" BorderBrush="{x:Null}" Background="{x:Null}" Value="{Binding DownloadHighResPicturesProgress}" Style="{DynamicResource ProgressBarStyle1}" VerticalAlignment="Top" Margin="0,0,2,0" Maximum="1" Foreground="#FF0ADA0D" Tag="Highres Pictures">
        		<i:Interaction.Triggers>
        			<i:EventTrigger EventName="ValueChanged">
        				<i:Interaction.Behaviors>
        					<ei:ConditionBehavior>
        						<ei:ConditionalExpression>
        							<ei:ComparisonCondition LeftOperand="{Binding DownloadHighResPicturesProgress}" Operator="GreaterThanOrEqual" RightOperand="1"/>
        						</ei:ConditionalExpression>
        					</ei:ConditionBehavior>
        				</i:Interaction.Behaviors>
        				<ei:ChangePropertyAction PropertyName="Visibility">
        					<ei:ChangePropertyAction.Value>
        						<Visibility>Collapsed</Visibility>
        					</ei:ChangePropertyAction.Value>
        				</ei:ChangePropertyAction>
        			</i:EventTrigger>
        			<i:EventTrigger EventName="ValueChanged">
        				<i:Interaction.Behaviors>
        					<ei:ConditionBehavior>
        						<ei:ConditionalExpression>
        							<ei:ComparisonCondition LeftOperand="{Binding DownloadHighResPicturesProgress}" RightOperand="0"/>
        						</ei:ConditionalExpression>
        					</ei:ConditionBehavior>
        				</i:Interaction.Behaviors>
        				<ei:ChangePropertyAction PropertyName="Visibility"/>
        			</i:EventTrigger>
        		</i:Interaction.Triggers>
        	</ProgressBar>
        </UniformGrid>
        <Grid x:Name="grid2" HorizontalAlignment="Center" VerticalAlignment="Bottom" Grid.RowSpan="27" Grid.ColumnSpan="85" Background="{DynamicResource HighlightBrush}" RenderTransformOrigin="0.5,0.5" Margin="0,0,0,50" Visibility="Hidden">
        	<i:Interaction.Triggers>
        		<i:EventTrigger EventName="TargetUpdated" SourceName="textBlock">
        			<ei:ControlStoryboardAction Storyboard="{StaticResource ShowMessageAnimation}"/>
        		</i:EventTrigger>
        	</i:Interaction.Triggers>
            <Grid.RenderTransform>
        		<TransformGroup>
        			<ScaleTransform/>
        			<SkewTransform/>
        			<RotateTransform/>
        			<TranslateTransform/>
        		</TransformGroup>
        	</Grid.RenderTransform>
        	<Grid.Effect>
        		<DropShadowEffect ShadowDepth="0" BlurRadius="19"/>
        	</Grid.Effect>
            <TextBlock x:Name="textBlock" Margin="10" TextWrapping="Wrap" VerticalAlignment="Center" d:LayoutOverrides="Width" HorizontalAlignment="Center" Foreground="White" FontSize="21.333" FontFamily="Segoe UI Light" Text="{Binding Message, NotifyOnTargetUpdated=True}" TargetUpdated="TextBlock_TargetUpdated" />
        </Grid>
    </Grid>
</Window>